package src.com.zt.demo.interal_class;

public class Demo3 {
    public OutInterface2 action(){  //返回接口对象
//      return new OutInterface2();
        return new OutInterface2() {    //实例化,匿名内部类在使用时才被创建，内部类的类体
            private int i =0;

            public int getValue(){
                return i;
            }
            };
        }
    }

interface OutInterface2{

}
